/**
 * 所有版权归 广西梧州 陈锦韬 所有
 *
 * @Title: SystemHandler
 * @Package com.rx.uua.handler
 * @Description: 关于系统管理的处理
 * @author: 陈锦韬
 * @date: 2021\7\7 0007
 * @version V1.0
 * @Copyright: 2021 陈锦韬  All rights reserved.
 */
package com.rx.school.handler;

import com.rx.core.base.RxBaseData;
import com.rx.core.dbase.RxMarkDbMust;
import com.rx.core.enm.HANDLER_TYPE;
import com.rx.core.handler.CommonHandler;
import com.rx.core.handler.RxHandler;
import com.rx.core.handler.RxHandlerAfter;
import com.rx.core.handler.RxHandlerContent;
import com.rx.core.service.StandardService;
import com.rx.core.util.RxUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.Arrays;

/**
 * @author: Administrator
 * @Description: 处理器。
 * @date: 2021\7\7 0007
 */
@RxHandler
@Slf4j
public class SchoolHandler implements RxHandlerContent {
    public static final String  RANDOM_PASSWORD="RANDOM_PASSWORD";

    @Autowired
    StandardService standardService;

    @Override
    public boolean handle(RxBaseData data) {
        return false;
    }

    /**
     * 返回创建者，更新者的ID
     * @param data
     * @return
     */
    @RxHandlerAfter(types= {HANDLER_TYPE.ALL},keys = {
        "sch-article-info"
    })
    public boolean returnPersonId(RxBaseData data){
        CommonHandler.showFields(data,
                Arrays.asList(
                RxUtil.StringUtil.lineToHump(RxMarkDbMust.CREATE_BY_ID),
                RxUtil.StringUtil.lineToHump(RxMarkDbMust.UPDATE_BY_ID)
        ));
        return false;
    }

}
